import axios from 'axios'
import util from "@/libs/util.js"
/**----------------示例模版-------------- */
let {
  pageConfig,
  // ajaxUrl
} = util.baseApi
let ajaxUrl = 'http://10.36.213.13:8090'
export const getExampleListAPI = ({
  current,
  pageSize
}, other = {}) => {
  let params = {
    [pageConfig.indexName]: current,
    [pageConfig.sizeName]: pageSize
  }
  Object.assign(params, other)
  return axios.get(`${ajaxUrl}/black/list`, {
    params
  })
}
//获取单个信息
export const getExampleAPI = (id) => {
  return axios.get(`${ajaxUrl}/black/` + id)
}
//修改信息
export const putExampleAPI = (data) => {
  return axios.put(`${ajaxUrl}/black`, data)
}
//审核
export const putblackAuditAPI = (data) => {
  return axios.put(`${ajaxUrl}/black/Audit`, data)
}
//添加信息 
export const addExampleAPI = (data) => {
  return axios.post(`${ajaxUrl}/black`, data)
}
//删除信息
export const delExampleAPI = (id) => {
  return axios.delete(`${ajaxUrl}/black/` + id)
}
export const mulDelExampleAPI = (ids) => {
  return axios.delete(`${ajaxUrl}/black`, {
    ids
  })
}
